﻿@{
    ViewBag.Title = "List";
}
@model List<TestHttpModules.User>
@section Head{
    <script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/jquery.unobtrusive-ajax.min.js")" type="text/javascript"></script>
    <script type="text/javascript">
        //        $(function () {
        //            $("#del").click(function () {
        //                var ids = $("#list").find(':checked'); var id = ''; ids.each(function (i, o) {
        //                    id += $(o).val() + ",";
        //                });
        //                $.ajax({ type: "POST",
        //                    url: '@Url.Action("Delete")',
        //                    data: { id: id },
        //                    success: function (data) {
        //                        if (data == "true") {
        //                            alert("操作成功");
        //                            location.href = location.href;
        //                        } else { alert("操作失败"); }
        //                    }
        //                });
        //            });
        //        });
        function DelAfter(data) {
            $("#Register").html("操作成功...").hide("slow");
        }
        function DelBefore() {
            $("#Register").remove();
            $("body").append('<div style="background: #eee; display: block; border: 1px solid; font-size: 14px;padding: 10px 10px 5px 10px; z-index: 1000; text-align: center; position: absolute;top:50px;left:200px;" id="Register">操作成功...</div>');
        }

    </script>
}
<div id="list">
@Html.Partial("List", Model)
</div>